.class Lcom/waiqin365/lightapp/product/view/d;
.super Ljava/lang/Object;

# interfaces
.implements Landroid/view/View$OnClickListener;


# instance fields
.field final synthetic a:Lcom/waiqin365/lightapp/product/view/CountView;


# direct methods
.method constructor <init>(Lcom/waiqin365/lightapp/product/view/CountView;)V
    .locals 0

    iput-object p1, p0, Lcom/waiqin365/lightapp/product/view/d;->a:Lcom/waiqin365/lightapp/product/view/CountView;

    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    return-void
.end method


# virtual methods
.method public onClick(Landroid/view/View;)V
    .locals 8

    const/4 v3, 0x0

    invoke-static {}, Lcom/waiqin365/lightapp/view/a/b;->a()Ljava/util/Observable;

    move-result-object v0

    iget-object v1, p0, Lcom/waiqin365/lightapp/product/view/d;->a:Lcom/waiqin365/lightapp/product/view/CountView;

    invoke-virtual {v0, v1}, Ljava/util/Observable;->addObserver(Ljava/util/Observer;)V

    iget-object v0, p0, Lcom/waiqin365/lightapp/product/view/d;->a:Lcom/waiqin365/lightapp/product/view/CountView;

    invoke-virtual {v0}, Lcom/waiqin365/lightapp/product/view/CountView;->e()Lcom/waiqin365/base/db/offlinedata/s;

    move-result-object v4

    if-eqz v4, :cond_2

    iget-object v0, p0, Lcom/waiqin365/lightapp/product/view/d;->a:Lcom/waiqin365/lightapp/product/view/CountView;

    invoke-virtual {v0}, Lcom/waiqin365/lightapp/product/view/CountView;->getContext()Landroid/content/Context;

    move-result-object v0

    invoke-static {v0}, Lcom/waiqin365/base/db/offlinedata/w;->a(Landroid/content/Context;)Lcom/waiqin365/base/db/offlinedata/w;

    move-result-object v0

    invoke-virtual {v4}, Lcom/waiqin365/base/db/offlinedata/s;->b()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Lcom/waiqin365/base/db/offlinedata/w;->d(Ljava/lang/String;)Ljava/util/List;

    move-result-object v5

    iget-object v0, p0, Lcom/waiqin365/lightapp/product/view/d;->a:Lcom/waiqin365/lightapp/product/view/CountView;

    invoke-virtual {v0}, Lcom/waiqin365/lightapp/product/view/CountView;->getContext()Landroid/content/Context;

    move-result-object v0

    invoke-static {v0}, Lcom/waiqin365/base/db/offlinedata/w;->a(Landroid/content/Context;)Lcom/waiqin365/base/db/offlinedata/w;

    move-result-object v0

    invoke-virtual {v4}, Lcom/waiqin365/base/db/offlinedata/s;->b()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Lcom/waiqin365/base/db/offlinedata/w;->f(Ljava/lang/String;)Lcom/waiqin365/base/db/offlinedata/s;

    move-result-object v6

    new-instance v1, Ljava/util/ArrayList;

    invoke-direct {v1}, Ljava/util/ArrayList;-><init>()V

    move v2, v3

    :goto_0
    invoke-interface {v5}, Ljava/util/List;->size()I

    move-result v0

    if-ge v2, v0, :cond_1

    new-instance v7, Lcom/waiqin365/lightapp/product/d/e;

    invoke-interface {v5, v2}, Ljava/util/List;->get(I)Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Lcom/waiqin365/base/db/offlinedata/s;

    invoke-direct {v7, v0}, Lcom/waiqin365/lightapp/product/d/e;-><init>(Lcom/waiqin365/base/db/offlinedata/s;)V

    if-eqz v6, :cond_0

    invoke-virtual {v6}, Lcom/waiqin365/base/db/offlinedata/s;->c()Ljava/lang/String;

    move-result-object v0

    invoke-virtual {v7, v0}, Lcom/waiqin365/lightapp/product/d/e;->e(Ljava/lang/String;)V

    :cond_0
    invoke-interface {v1, v7}, Ljava/util/List;->add(Ljava/lang/Object;)Z

    add-int/lit8 v0, v2, 0x1

    move v2, v0

    goto :goto_0

    :cond_1
    new-instance v0, Ljava/util/ArrayList;

    invoke-direct {v0}, Ljava/util/ArrayList;-><init>()V

    invoke-virtual {v4}, Lcom/waiqin365/base/db/offlinedata/s;->a()Ljava/lang/String;

    move-result-object v2

    invoke-interface {v0, v2}, Ljava/util/List;->add(Ljava/lang/Object;)Z

    new-instance v2, Landroid/content/Intent;

    iget-object v4, p0, Lcom/waiqin365/lightapp/product/view/d;->a:Lcom/waiqin365/lightapp/product/view/CountView;

    invoke-virtual {v4}, Lcom/waiqin365/lightapp/product/view/CountView;->getContext()Landroid/content/Context;

    move-result-object v4

    const-class v5, Lcom/waiqin365/lightapp/dailyreport/SimpleSelectMultActivity;

    invoke-direct {v2, v4, v5}, Landroid/content/Intent;-><init>(Landroid/content/Context;Ljava/lang/Class;)V

    const-string/jumbo v4, "selected"

    check-cast v0, Ljava/io/Serializable;

    invoke-virtual {v2, v4, v0}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/io/Serializable;)Landroid/content/Intent;

    const-string/jumbo v4, "list"

    move-object v0, v1

    check-cast v0, Ljava/io/Serializable;

    invoke-virtual {v2, v4, v0}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/io/Serializable;)Landroid/content/Intent;

    const-string/jumbo v0, "title"

    iget-object v1, p0, Lcom/waiqin365/lightapp/product/view/d;->a:Lcom/waiqin365/lightapp/product/view/CountView;

    invoke-virtual {v1}, Lcom/waiqin365/lightapp/product/view/CountView;->getContext()Landroid/content/Context;

    move-result-object v1

    const v4, 0x7f08073b

    invoke-virtual {v1, v4}, Landroid/content/Context;->getString(I)Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v2, v0, v1}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    const-string/jumbo v0, "isShowSearch"

    invoke-virtual {v2, v0, v3}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Z)Landroid/content/Intent;

    const-string/jumbo v0, "isSingleSelect"

    const/4 v1, 0x1

    invoke-virtual {v2, v0, v1}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Z)Landroid/content/Intent;

    const-string/jumbo v0, "returnTo"

    iget-object v1, p0, Lcom/waiqin365/lightapp/product/view/d;->a:Lcom/waiqin365/lightapp/product/view/CountView;

    iget-object v1, v1, Lcom/waiqin365/lightapp/product/view/CountView;->a:Ljava/lang/String;

    invoke-virtual {v2, v0, v1}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    iget-object v0, p0, Lcom/waiqin365/lightapp/product/view/d;->a:Lcom/waiqin365/lightapp/product/view/CountView;

    invoke-virtual {v0}, Lcom/waiqin365/lightapp/product/view/CountView;->getContext()Landroid/content/Context;

    move-result-object v0

    invoke-virtual {v0, v2}, Landroid/content/Context;->startActivity(Landroid/content/Intent;)V

    :cond_2
    return-void
.end method
